<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/webpage/include/taglib.jsp"%>
<%@ include file="/webpage/include/weChatHead.jsp"%>
<html>
<head>
<title>项目列表</title>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport"
	content="width=device-width, initial-scale=1, user-scalable=no">
<link href="${ctxStatic}/plugin/jquery-weui/lib/weui.min.css" " type="text/css"
	rel="stylesheet" />
<link href="${ctxStatic}/plugin	/jquery-weui/css/jquery-weui.css"
	type="text/css" rel="stylesheet" />

<script type="text/javascript">
	$(document).ready(function() {
	});
</script>
<style type="text/css">
#inbottom {
	position: fixed;
	bottom: 0;
	left: 0;
	width: 100%;
	height: 40px;
	background-color: #ffffff
}
</style>
<!--[if IE 6]> 
<style type="text/css">
html{overflow:hidden;}
body{height:100%;overflow:auto;}
#inbottom{position:absolute;}
</style>
<![endif]-->
</head>
<body>
	<div class="wrapper wrapper-content" style="padding-bottom:60px">
		<h2 style="margin-top: 0px">${projectInfo.projectName}</h2>
		<p style="font-size: 14px;padding: 5px">项目经理：${projectInfo.projectManager.name}</p>
		<p style="font-size: 14px;padding: 5px">项目成员：${projectMember}</p>
		<form:form id="searchForm" modelAttribute="projectInfo"
			action="${ctx}/project/dynamic/projectDynamic/weChatDetail"
			method="post" class="form-inline">
			<form:hidden path="id" />
			<input id="stage" name="stage" type="hidden"/>
			<div class="weui_cell">
       			<div class="weui_cell_hd"><label for="name" class="weui_label">项目阶段</label></div>
       	 		<div class="weui_cell_bd weui_cell_primary">
          			<input class="weui_input" id="stages" type="text">
        		</div>
      		</div>
		</form:form>
		<c:forEach items="${list}" var="projectDynamic">
			<div class="weui_panel" style="margin-top: 0px">
				<div class="weui_panel_bd">
					<div class="weui_media_box weui_media_text" style="padding: 3px">
						<ul class="weui_media_info">
							<font style="line-height:1.5;color: #000000;font-size: 15px">${projectDynamic.content}</font>
							<div style="margin-top: 5px">
								<li class="weui_media_info_meta">${projectDynamic.createBy.name}</li>
								<li class="weui_media_info_meta pull-right" style="margin: 0px;padding: 0px">
									<fmt:formatDate value="${projectDynamic.createDate}" type="both"
										pattern="yyyy.MM.dd HH:mm:ss" />
								</li>
							</div>
						</ul>
					</div>
				</div>
			</div>
		</c:forEach>
	</div>
	<div class="wrapper wrapper-content" id="inbottom">
		<a href="${ctx}/project/dynamic/projectDynamic/weChatAdd?projectInfo.id=${projectInfo.id}" 
		class="weui_btn weui_btn_primary" style="margin-right: 40px">添加动态</a>
	</div>
	<script type="text/javascript">
		function doSubmit() {//回调函数，在编辑和保存动作时，供openDialog调用提交表单。
			$("#searchForm").submit();
		}
	</script>
<!-- body 最后 -->
<script src="${ctxStatic}/plugin/jquery-weui/js/jquery-weui.js" type="text/javascript"></script>
<script src="${ctxStatic}/plugin/jquery-weui/js/jquery-weui.min.js" type="text/javascript"></script>

<!-- 如果使用了某些拓展插件还需要额外的JS -->
<script src="${ctxStatic}/plugin/jquery-weui/js/swiper.min.js" type="text/javascript"></script>
<script src="${ctxStatic}/plugin/jquery-weui/js/city-picker.min.js" type="text/javascript"></script>
<script>
  $("#stages").select({
    title: "选择项目阶段",
    items: [ {
      	title: "方案研究",
      	value: "1",
    	},
      {
        title: "预可",
        value: "2",
      },
      {
        title: "工可",
        value: "3",
      },
      {
        title: "初步设计",
        value: "4",
      },
      {
        title: "施工图设计",
        value: "5",
      },
      {
        title: "后期服务",
        value: "6",
      }],
      onChange: function(d) {
          $("#stage").val(d.values);
          doSubmit();
      }
  });
</script>
</body>
</html>